export default {
    namespaced: true,
    state: {
        cartList: JSON.parse(sessionStorage.getItem("cartList")),
        routerType: 'push'
    },

    mutations: {
        changRouterType (state, newRouterType) {
            state.routerType = newRouterType
        },
        setCart (state, cartlist) {
            sessionStorage.setItem("cartList", JSON.stringify(cartlist));
            // console.log(state.cartList.length)
        },


    },
    getters: {
        routerType: (state) => state.routerType
    },
    actions: {
    },
}